﻿
    using Chain.BLL;
    using Chain.Model;
    using System;
    using System.Web.UI.HtmlControls;
    using System.Web.UI.WebControls;

    public partial class ShopInfo : PageBase
    {


        protected void Page_Load(object sender, EventArgs e)
        {
            if (!base.IsPostBack)
            {
                if (base.Request.QueryString["SID"] != null)
                {
                    this.HidSid.Value = base.Request.QueryString["SID"];
                }
                PubFunction.BindShopArea(this.sltShopAreaID, true);
                this.Set_ShopInfo();
            }
        }

        public void Set_ShopInfo()
        {
            if (this.HidSid.Value != "")
            {
                Chain.Model.SysShop shop = new Chain.BLL.SysShop().GetModel(int.Parse(this.HidSid.Value));
                this.lblFrmTitle.Text = this.lblFrmTitle.Text + "--" + shop.ShopName + "  店铺编辑";
                int AreaID = shop.ShopAreaID;
                new Chain.BLL.SysArea().GetModel(AreaID);
                this.txtShopName.Value = shop.ShopName;
                this.txtShopID.Value = shop.ShopID.ToString();
                this.txtShopContactMan.Value = shop.ShopContactMan;
                this.txtShopTelephone.Value = shop.ShopTelephone;
                this.txtShopAddress.Value = shop.ShopAddress;
                this.txtShopRemark.Value = shop.ShopRemark;
                this.txtShopPrintTitle.Value = shop.ShopPrintTitle;
                this.txtShopPrintFoot.Value = shop.ShopPrintFoot;
                if (shop.ShopState)
                {
                    this.radChooseYes.Checked = true;
                }
                else
                {
                    this.radChooseNo.Checked = true;
                }
            }
            else
            {
                this.lblFrmTitle.Text = this.lblFrmTitle.Text + "--  店铺设置";
            }
        }
    }


